package com.seu.design.pattern.creational.simplefactory;

/**
 * Created by seu-lfh
 */
public class Test {

    public static void main(String[] args) {
        VideoFactory videoFactory = new VideoFactory();
        Video video2 = videoFactory.getVideo("java");
        if (video2 == null) {
            return;
        }
        video2.produce();

        VideoFactory videoFactory2 = new VideoFactory();
        Video video = videoFactory2.getVideo(JavaVideo.class);
        if (video == null) {
            return;
        }
        video.produce();


    }

}
